
package com.apcc4m.sfpushbatch.service;

import java.net.URI;

import org.java_websocket.client.WebSocketClient;
import org.java_websocket.drafts.Draft;
import org.java_websocket.handshake.ServerHandshake;

import com.apcc4m.sfpushbatch.common.PushMessage;


public class MyWebSocketClient extends WebSocketClient {

    public MyWebSocketClient(URI serverUri, Draft draft) {
        super(serverUri, draft);
    }

    @Override
    public void onOpen(ServerHandshake arg0) {
    }

    @Override
    public void onClose(int arg0, String reason, boolean arg2) {
    }

    @Override
    public void onError(Exception exception) {
    }

    @Override
    public void onMessage(String jsonStr) {
    }

    public void send(PushMessage msg) {
        this.send(msg.toString());
    }
}
